Skip to content

[HUDI-5283] Replace deprecated method Schema.parse With Schema.Parser.#7308

Merged
danny0405 merged 1 commit intoapache:masterfrom
slfan1989:HUDI-5283
Nov 28, 2022
Merged

[HUDI-5283] Replace deprecated method Schema.parse With Schema.Parser.#7308
danny0405 merged 1 commit intoapache:masterfrom
slfan1989:HUDI-5283

Conversation

@slfan1989
Copy link
Copy Markdown
Contributor

Change Logs

JIRA: HUDI-5283. Replace deprecated method Schema.parse With Schema.Parser.

When reading the code, I found that HoodieBootstrapSchemaProvider#getBootstrapSchema uses the deprecated method Schema.parse, which can be replaced by Schema.Parser().parse(),
At the same time, I searched at the moudle level, only to find that this place uses an deprecated method.

Impact

none.

Risk level (write none, low medium or high below)

none.

Documentation Update

none.

Contributor's checklist

  • Read through contributor's guide
  • Change Logs and Impact were stated clearly
  • Adequate tests were added if applicable
  • CI passed

@slfan1989
Copy link
Copy Markdown
Contributor Author

@yihua Can you help review this pr? Thank you very much! Can you allow me to assign jira?
image

Copy link
Copy Markdown
Contributor

@danny0405 danny0405 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1

@danny0405 danny0405 self-assigned this Nov 28, 2022
@danny0405 danny0405 added priority:medium Moderate impact; usability gaps type:refactor Code refactoring and cleanup labels Nov 28, 2022
@hudi-bot
Copy link
Copy Markdown
Collaborator

CI report:

Bot commands @hudi-bot supports the following commands:
  • @hudi-bot run azure re-run the last Azure build

@danny0405
Copy link
Copy Markdown
Contributor

The failed test case: ITTestHoodieDataSource#testBatchUpsertWithMiniBatches should not be affected by this patch, would merge it soon ~

@danny0405 danny0405 merged commit ddcd045 into apache:master Nov 28, 2022
if (writeConfig.getSchema() != null) {
// Use schema specified by user if set
Schema userSchema = Schema.parse(writeConfig.getSchema());
Schema userSchema = new Schema.Parser().parse(writeConfig.getSchema());
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see one more usage in AvroFileDeltaInputWriter in hudi-integ-test. Though it's not critical but would be good to fix there as well.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oops, didn't see it, @slfan1989 , can you fire another minor PR to track this.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for helping to review the code @codope @danny0405 , I will continue to follow up.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@codope I will modify it to the mock method.

satishkotha pushed a commit to satishkotha/incubator-hudi that referenced this pull request Dec 12, 2022
fengjian428 pushed a commit to fengjian428/hudi that referenced this pull request Apr 5, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

priority:medium Moderate impact; usability gaps type:refactor Code refactoring and cleanup

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants